<!DOCTYPE html>
<html>
	<head>
		<title>CSV Parser</title>
		<link rel="stylesheet" href="../../../codebase/webix.css" type="text/css" charset="utf-8">
		<script src="../../../codebase/webix.js" type="text/javascript" charset="utf-8"></script>

		<link rel="stylesheet" type="text/css" href="../common/samples.css">
		<script src="../common/testdata.js" type="text/javascript" charset="utf-8"></script>
	</head>
	<body>
		<div class='header_comment'>CSV parser</div>
		<div class='sample_comment'>Copy CSV from the textarea to the datatable.</div>
 		<div class='sample_comment'> Use ctrl+c and ctrl+v to copy and paste content.</div>
		<div id="testA"></div>
		<hr>
		<div style="padding: 20px;">
		CSV data:<br>
		<textarea style="width: 250px; height: 80px;">,	1	"2 """	"3
17"
";""4"	5	6	";7"</textarea>
		</div>
		
		<script type="text/javascript" charset="utf-8">
		var grid;
		webix.csv.escape = true;
		webix.ready(function(){
			grid = webix.ui({
				container:"testA",
				view:"datatable",
				columns:[
					{ id:"rank",	header:"", css:"rank",  		width:50},
					{ id:"title",	header:"Film title",width:200},
					{ id:"year",	header:"Released" , width:80},
					{ id:"votes",	header:"Votes", 	width:100}
				],
				select:"cell",
				blockselect:true, 
				clipboard:"selection",

				autoheight:true,
				autowidth:true,
				data:small_film_set
			});		
		});
		</script>
	</body>
</html>